#define _CRT_SECURE_NO_WARNINGS
#define inchs 2.54
#define feets 30.48
#include<stdio.h>
int main()
{
    int feet;
    float i, inch;
    scanf("%f", &i);
    while (i > 0)
    {
        feet = i / feets;
        inch = (i - feet*feets) / inchs;
        printf("%d   %.1f", feet, inch);
        scanf("%f", &i);
    }
    return 0;
}